#include <iostream>

using namespace std;
using LL = long long;
const int mod = 9901;

int qmi(int p, int k){
    int res = 1;
    while(k){
        if(k & 1) res = (LL)res * p % mod;
        k >>= 1;
        p = (LL)p * p % mod;
    }
    return res;
}

int sum(int p, int c){
    if(c == 0) return 1;
    if(c == 1) return (1 + p) % mod;
    
    if(c % 2){
        return ((LL)1 + qmi(p, (c + 1) / 2)) % mod * sum(p, (c - 1) / 2) % mod;
    }else{
        return (((LL)1 + qmi(p, c / 2)) % mod * sum(p, c / 2 - 1) % mod + qmi(p, c)) % mod;
    }
}



int main(){
    int a, b;
    cin >> a >> b;
    
    int res = 1;
    for(int i = 2; i <= a; i ++){
        if(a % i == 0){
            int t = 0;
            while(a % i == 0){
                a /= i;
                t ++;
            }
            res = (res * sum(i, b * t)) % mod; 
        }
    }
    if(!a) cout << 0 << '\n';
    else cout << res;
    
    return 0;
}